Optimal. Leaf size=32 \[ \frac{a (B+C) \tanh ^{-1}(\sin (c+d x))}{d}+a B x+\frac{a C \tan (c+d x)}{d} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.0717028, antiderivative size = 32, normalized size of antiderivative = 1., number of steps used = 5, number of rules used = 5, integrand size = 36, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.139, Rules used = {4072, 3914, 3767, 8, 3770} \[ \frac{a (B+C) \tanh ^{-1}(\sin (c+d x))}{d}+a B x+\frac{a C \tan (c+d x)}{d} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 4072
Rule 3914
Rule 3767
Rule 8
Rule 3770
Rubi steps
\begin{align*} \int \cos (c+d x) (a+a \sec (c+d x)) \left (B \sec (c+d x)+C \sec ^2(c+d x)\right ) \, dx &=\int (a+a \sec (c+d x)) (B+C \sec (c+d x)) \, dx\\ &=a B x+(a C) \int \sec ^2(c+d x) \, dx+(a (B+C)) \int \sec (c+d x) \, dx\\ &=a B x+\frac{a (B+C) \tanh ^{-1}(\sin (c+d x))}{d}-\frac{(a C) \operatorname{Subst}(\int 1 \, dx,x,-\tan (c+d x))}{d}\\ &=a B x+\frac{a (B+C) \tanh ^{-1}(\sin (c+d x))}{d}+\frac{a C \tan (c+d x)}{d}\\ \end{align*}
Mathematica [A] time = 0.0143111, size = 43, normalized size = 1.34 \[ \frac{a B \tanh ^{-1}(\sin (c+d x))}{d}+a B x+\frac{a C \tan (c+d x)}{d}+\frac{a C \tanh ^{-1}(\sin (c+d x))}{d} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A] time = 0.065, size = 65, normalized size = 2. \begin{align*} aBx+{\frac{Ba\ln \left ( \sec \left ( dx+c \right ) +\tan \left ( dx+c \right ) \right ) }{d}}+{\frac{Bac}{d}}+{\frac{aC\ln \left ( \sec \left ( dx+c \right ) +\tan \left ( dx+c \right ) \right ) }{d}}+{\frac{aC\tan \left ( dx+c \right ) }{d}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [B] time = 0.940278, size = 99, normalized size = 3.09 \begin{align*} \frac{2 \,{\left (d x + c\right )} B a + B a{\left (\log \left (\sin \left (d x + c\right ) + 1\right ) - \log \left (\sin \left (d x + c\right ) - 1\right )\right )} + C a{\left (\log \left (\sin \left (d x + c\right ) + 1\right ) - \log \left (\sin \left (d x + c\right ) - 1\right )\right )} + 2 \, C a \tan \left (d x + c\right )}{2 \, d} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [B] time = 0.525431, size = 220, normalized size = 6.88 \begin{align*} \frac{2 \, B a d x \cos \left (d x + c\right ) +{\left (B + C\right )} a \cos \left (d x + c\right ) \log \left (\sin \left (d x + c\right ) + 1\right ) -{\left (B + C\right )} a \cos \left (d x + c\right ) \log \left (-\sin \left (d x + c\right ) + 1\right ) + 2 \, C a \sin \left (d x + c\right )}{2 \, d \cos \left (d x + c\right )} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F] time = 0., size = 0, normalized size = 0. \begin{align*} a \left (\int B \cos{\left (c + d x \right )} \sec{\left (c + d x \right )}\, dx + \int B \cos{\left (c + d x \right )} \sec ^{2}{\left (c + d x \right )}\, dx + \int C \cos{\left (c + d x \right )} \sec ^{2}{\left (c + d x \right )}\, dx + \int C \cos{\left (c + d x \right )} \sec ^{3}{\left (c + d x \right )}\, dx\right ) \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [B] time = 1.13647, size = 113, normalized size = 3.53 \begin{align*} \frac{{\left (d x + c\right )} B a +{\left (B a + C a\right )} \log \left ({\left | \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right ) + 1 \right |}\right ) -{\left (B a + C a\right )} \log \left ({\left | \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right ) - 1 \right |}\right ) - \frac{2 \, C a \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )}{\tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )^{2} - 1}}{d} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]